<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>固定定位</title>

    <style>
        .box{
            width: 200px;
            height: 200px;
            background: #000;
            position: fixed;
            left: 100px;
            top: 200px;
        }
        body{
            height: 3000px;
        }
    </style>

</head>
<body>
    <div class="box"></div>
</body>
</html>